<template>
	<view>
		<!-- 营业额 -->
		<view class="turnover" v-if="list.length > 0">
			<view class="turnover-item" v-for="(item,index) in list" :key="index" @click="tolist">
				<view class="turn-title" style="box-sizing: content-box;">
					<view class="turn-t">{{item.title}}</view>
					<view class="turn-con">
						{{item.abstract}}
					</view>
				</view>
				<view class="turn-image">
					<image class="image" :src="item.cover_pic" mode=""></image>
					<image class="play"
						:src="imgprefix+'/web/uploads/mall1/20210331/50af8c15686da2c9044ce0769d010b3f.png'"></image>
				</view>
			</view>
		</view>
		<view class="" v-else>
			暂无信息
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				value: ['5000-10000元'],
				list: [],
				imgprefix: this.$siteInfo.imgroot
			}
		},
		onLoad() {
			// this.imgprefix = this.$siteInfo.imgroot
			this.loadlist()
			uni.showShareMenu({
				menus: ['shareAppMessage', 'shareTimeline']
			})
		},
		onShareAppMessage() {
			return this.$shareAppMessage({
				title: '营业额',
				path: '/pages/turnover/index',
				params: {

				}
			});
		},
		onShareTimeline() {
			return this.$shareTimeline({
				title: '营业额',
				query: {

				}
			});
		},
		methods: {
			loadlist() {
				this.$request({
					url: this.$api.topic.list,
					data: {
						type: 3
					}
				}).then((res) => {
					this.list = res.data.list
				}).catch(err => {

				})
			},
			tolist() {
				uni.navigateTo({
					url: '/pages/turnover/videolist'
				})
			},
			change(e) {
				// console.log(e);
			}
		}
	}
</script>

<style scoped lang="scss">
	.turnover {
		width: 686rpx;
		margin: 0 auto;
	}

	.turnover-item {
		margin-top: 24rpx;
		width: 100%;
		height: 264rpx;
		background-color: #FFFFFF;
		border-radius: 32rpx;
		display: flex;
		justify-content: space-between;
		overflow: hidden;
	}

	.turn-title {
		width: 252rpx;
		padding: 40rpx 32rpx;
		font-size: 24rpx;
	}

	.turn-t {
		font-size: 28rpx;
		font-weight: bold;
		color: #333333;
		line-height: 42rpx;
	}

	.turn-con {
		text-align: justify;
		line-height: 36rpx;
		color: #666666;
		margin: 24rpx 0;
		overflow: hidden;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-line-clamp: 3;
		-webkit-box-orient: vertical;
		text-align: justify;
	}

	.turn-image {
		width: 370rpx;
		height: 264rpx;
		overflow: hidden;
		// border-radius: 32rpx;
		position: relative;
	}

	.turn-image .image {
		width: 100%;
		height: 100%;
	}

	.turn-image .play {
		position: absolute;
		width: 80rpx;
		height: 80rpx;
		left: 50%;
		top: 50%;
		transform: translate(-50%, -50%);
	}
</style>
